package tedu.week04.day02_thread.lesson1;

/**
 * <pre>
 *      线程的后台操作.
 * </pre>
 *
 * @author : resty
 * @date : 2019年07月08日    21时
 **/
public class ThreadDaemon implements Runnable {
    @Override
    public void run() {
        while(true){
            System.out.println(Thread.currentThread().getName());
        }
    }

    public static void main(String[] args){
        Thread t = new Thread(new ThreadDaemon());
        t.setDaemon(true);
        System.out.println(t.isDaemon());
        t.start();
    }
}
